<include file="Public/header" /> 

<!--主窗体-->
<div class="container app">
	<!--左侧菜单-->
	<include file="Public/sidebar" /> 
	<!--左侧菜单//-->	
	
	<!-- mainCon -->
	<div id="mainCon" class="mainCon">
		<h4>会员列表</h4>
		<div>
			<form class="form-inline" >
				<div class="form-group form-group-sm">
					<label for="member_level">等级：</label>
					<select id="member_level" name="member_level" class="form-control">
						<option value="-1">全部</option>
						<foreach name="level_list" key="key" item="value" >
							<option value="<{$key}>" <?php if ($key == $member_level) { echo 'selected="selected"'; } ?> ><{$value}></option>
						</foreach>
					</select>
				</div>
				<div class="bk10"></div>
				<div class="form-group form-group-sm">
					<label for="">注册时间：</label>
					
					<input type="text" class="form-control laydate-icon" id="start_time" name="start_time"  value="<{$start_time?($start_time|date='Y-m-d H:i:s',###):''}>" >
					<span>-</span>
					<input type="text" class="form-control laydate-icon" id="end_time" name="end_time"  value="<{$end_time?($end_time|date='Y-m-d H:i:s',###):''}>" >
				</div>
				<button type="submit" class="btn btn-default btn-sm">查询会员</button>
				<div class="bk10"></div>
				<div class="form-group form-group-sm">
					<label for="">总共&nbsp;<{$total}>&nbsp;位会员</label>
				</div>
				<input type="hidden" name="p" value="0">
			</form>
		</div>
		<table class="table table-bordered table-hover">
			<tr>
				<th>编号</th>
				<th>昵称</th>
				<th>注册时间</th>
				<th>会员等级</th>
			</tr>
			
			<empty name="member_list">
				<tr><td colspan="9" style="text-align:center;color:#999">～暂无数据～</td></tr>
			<else /> 
			
				<foreach name="member_list" item="vo">
					<tr>
						<td><{$vo['id']}></td>
						<td><{$vo['username']}></td>
						<td><{$vo['createtime']|date="Y-m-d H:i:s",###}></td>
						<td <if condition="$vo['level'] eq 1">style="color:#D00534;"</if> >
							<{$level_list[$vo['level']]}>
						</td>
					</tr>
				</foreach>
			</empty> 
		</table>
		
		<div class="pagebar">
			<{$pager}>
		</div>
		
	</div>
	<!-- mainCon// -->
	
</div>
<!--主窗体//-->

<script src="__PUBLIC__/js/layer/layer.js"></script>
<script>

$(function(){

	var start = {
		elem: '#start_time',
		format: 'YYYY/MM/DD hh:mm:ss',
		istime: true,
		istoday: false,
		choose: function(datas){
			 end.min = datas; //开始日选好后，重置结束日的最小日期
			 end.start = datas //将结束日的初始值设定为开始日
		}
	};
	var end = {
		elem: '#end_time',
		format: 'YYYY/MM/DD hh:mm:ss',
		istime: true,
		istoday: false,
		choose: function(datas){
			start.max = datas; //结束日选好后，重置开始日的最大日期
		}
	};
	laydate(start);
	laydate(end);
});
</script>
<include file="Public/footer" /> 